import request from '@/config/axios'

// 获得会员权益列表
export const getBenefitsList = async () => {
  return await request.get({ url: `/member/benefits/getList` })
}

// 新增会员权益
export const createBenefits = async (data) => {
  return await request.post({ url: `/member/benefits/create`, data })
}

// 修改会员权益
export const updateBenefits = async (data) => {
  return await request.put({ url: `/member/benefits/update`, data })
}

// 删除会员权益
export const deleteBenefits = async (id) => {
  return await request.delete({ url: `/member/benefits/delete?id=` + id })
}
// 舌诊权益
export const getBenefitsListTongue = async () => {
  return await request.get({ url: `/member/benefits/getTongueCountList` })
}

// 舌诊删除
export const deleteTongueCount = async (level: string) => {
  return await request.delete({ url: `/member/benefits/deleteTongueCount?level=` + level })
}
// member/benefits/saveTongueCount
export const saveTongueCount = async (data) => {
  return await request.post({ url: `/member/benefits/saveTongueCount`, data })
}
